
function initialize ( route ,port) {
    var server = require('http').createServer();
    var url = require('url');
    function control(petic, resp) {
        var pathName = url.parse(petic.url).pathname;
        console.log('Request received');
        var result= ""
        resp.writeHead(200, {'content-type': 'text/plain'});
        route(pathName);
        resp.write("successfully");
        resp.end();
    }
    server.on('request', control).listen(port);
    console.log('server was initialized');
}
exports.initialize = initialize;
